import Theme from "vitepress/dist/client/theme-default";
import BrevityUI from "../../../src/entry";

// 引入主题样式、插件的组件、主要是demo组件(类似Element组件库文档的插件vitepress-theme-demoblock, 实现组件与代码一起展示的效果)
import "vitepress-theme-demoblock/theme/styles/index.css";
import Demo from "vitepress-theme-demoblock/components/Demo.vue";
import DemoBlock from "vitepress-theme-demoblock/components/DemoBlock.vue";

export default {
  // 引入Theme主题获取vue实例
  ...Theme,
  // 在enhanceApp方法中注册组件库插件, 这样md文件中即可使用vue组件
  enhanceApp({ app }) {
    app.use(BrevityUI);
    app.component("Demo", Demo);
    app.component("DemoBlock", DemoBlock);
  },
};
